<template>
  <div>{{ people }}</div>
  <button @click="editName">修改名字</button>
</template>
<script>
export default {
  props: ['people'],
  emits: ['changePeople'],
  setup(props, { emit }) {
    const editName = () => {
      console.log('111')
      emit('changePeople', { name: '韩小二', age: 18 })
    }
    return { editName }
  },
}
</script>
